import React from 'react';
import Ylcsimg from '../img/diy/ylcs-img.png'
import FacialmaskMaterial from './FacialmaskMaterial.js'
class Facialmaskylcs extends React.Component {
	constructor(props) {
	    super(props);
	    this.state = {
	       show:false
	    }
	}
	componentDidMount(){
        sessionStorage.setItem("scrollAct","true")
	}
    openCover(){
        sessionStorage.setItem("scrollAct","false")
        this.setState({
            show:true
        })
    }
    closeCover(){
        sessionStorage.setItem("scrollAct","true")
        this.setState({
            show:false
        })
    }
    render() {
        return (
            <div>
            	<div className="fmylcs-container boxshaw" onClick={this.openCover.bind(this)}>
            		<img src={Ylcsimg} className="fmylcs-container-img1"/>
                    <span>原料常识</span>
            	</div>
                <div>
                    
                </div>
                {this.state.show?<FacialmaskMaterial words={this.props.words} callbackParent={this.closeCover.bind(this)}  />:""}
            </div>
        )
    }
}


export default Facialmaskylcs;